package com.t11.common.pojo;

public class ResultMsg {


    private final Integer code;
    private final String msg;


    public ResultMsg(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }


    public Integer getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }


    public static final ResultMsg USER_NULL = new ResultMsg(0, "用户不存在");
    public static final ResultMsg SECKILL_SUCCESS = new ResultMsg(1, "抢购成功，排队中");
    public static final ResultMsg PAY_FAIL = new ResultMsg(2, "支付失败");
    public static final ResultMsg STOCK_NULL = new ResultMsg(3, "库存不足");
    public static final ResultMsg IS_PREEMPTION = new ResultMsg(4, "已预占，抢购商品只能买一次");
    public static final ResultMsg IS_BUY = new ResultMsg(5, "已购买成功，不可重复购买");

}
